package com.blackhorse.order;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.domain.EntityScan;
import org.springframework.cloud.client.circuitbreaker.EnableCircuitBreaker;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.cloud.netflix.hystrix.dashboard.EnableHystrixDashboard;
import org.springframework.cloud.openfeign.EnableFeignClients;
@EnableHystrixDashboard //激活hystrix图形化监控平台
@EnableCircuitBreaker //激活hystrix
@EnableFeignClients //激活Feign
@EnableEurekaClient//激活Eureka客户端
@SpringBootApplication//订单微服务 启动类
@EntityScan("com.blackhorse.order.entity")//Spring Data Jpa 实体类包扫描
public class OrderFeignApplication {

    //使用Feign之后不需要再手动使用RestTemplate

    public static void main(String[] args) {
        SpringApplication.run(OrderFeignApplication.class, args);
    }
}

